#include <stdio.h>

void main()
{
    int i = 2000;
    int *pointer;
    pointer = &i;
    // printf("*pointer=%d\n", *pointer);
    // printf("pointer=%p\n", pointer);
    // printf("&pointer=%p", &pointer);

    int k = 1;
    printf("%d\n", k);
    printf("%p\n", &k);

    /*
        b == &b[0];
    */
    int b[5] = {0,1,2,3,4}; 
    printf("b1=%p\n", b);
    printf("b2=%p\n", &b[0]);

    int a[5] = {0,1,2,3,4}; 
    int *p;

    /*
        通过下标来遍历数组
    */
    for(int j;j<5;j++){
        printf("%d\n",a[j]);
    }

    /*
        通过地址来遍历数组
    */
   for(int c;c<5;c++){
       printf("sss");
        printf("%d\n",*(a+c));
    }

    /*
        通过指针来遍历数组
    */
    for(p=a;p<a+5;p++){
        // printf("%d\n",a[j]);
        // printf("%d\n",*(a+i));
        printf("%d\n",*p);
    }
}